package cn.oracle.eshop.auth.dao.impl;

import cn.oracle.eshop.auth.dao.AccountPriorityRelationshipDAO;
import cn.oracle.eshop.auth.dao.RolePriorityRelationshipDAO;
import cn.oracle.eshop.auth.mapper.RolePriorityRelationshipMapper;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Repository;

/**账号和权限关系管理模块的DAO组件
 * @author wyh
 * @ClassName RolePriorityRelationshipDAOImpl
 * @date 2022/1/22 /18:13
 */
@Repository
public class AccountPriorityRelationshipDAOImpl implements AccountPriorityRelationshipDAO {
    /**角色和权限关系管理模块的mapper组件*/
    @Autowired
    private RolePriorityRelationshipMapper rolePriorityRelationshipMapper;
    /***
     * 根据权限iD查询记录数
     * @author wyh
     * @date 2022/1/22
     * @param priorityId 权限ID
     * @return java.lang.Long 记录数
     */
    @Override
    public Long getCountByPriorityId(Long priorityId) {
        return rolePriorityRelationshipMapper.getCountByPriorityId(priorityId);
    }
}
